package com.communal.model.cr;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.MappedSuperclass;

import com.communal.model.ModelEntity;

/**
 * Base entity class fo communal payment
 * @author Created by andrey.kuznetsov <br>
 * @author Last modified by $Author$ <br>
 * @author Last modified on $Date$ at revision $Revision$ <br>
 */
@MappedSuperclass
public class CommunalRecord extends ModelEntity implements Serializable{
	
	private static final long serialVersionUID = -8984928414968073688L;

	@Column(name = "month", unique = false, nullable = false, insertable = true, updatable = true)
	protected Short month;

	@Column(name = "year", unique = false, nullable = false, insertable = true, updatable = true)
	protected Short year;
	
	@Column(name = "date", unique = false, nullable = true, insertable = true, updatable = true)
	protected Long date;
	
	@Column(name = "summa", unique = false, nullable = false, insertable = true, updatable = true)
	protected Double summa;

	/**
	 * Returns month for which payment should be excuted <br>
	 * @return {@link Short}
	 */
	public Short getMonth() {
		return month;
	}

	/**
	 * Sets month for which payment should be excuted <br>
	 * @param p_month - {@link Short};
	 */
	public void setMonth(Short p_month) {
		month = p_month;
	}

	/**
	 * Returns year for which payment should be excuted <br>
	 * @return {@link Short};
	 */
	public Short getYear() {
		return year;
	}

	/**
	 * Sets year for which payment should be excuted <br>
	 * @param p_year - {@link Short};
	 */
	public void setYear(Short p_year) {
		year = p_year;
	}

	/**
	 * Returns date of payment <br>
	 * @return {@link Long};
	 */
	public Long getDate() {
		return date;
	}

	/**
	 * Sets date of payment <br>
	 * @param p_date - {@link Long};
	 */
	public void setDate(Long p_date) {
		date = p_date;
	}

	/**
	 * Returns summa of payment <br>
	 * @return {@link Double};
	 */
	public Double getSumma() {
		return summa;
	}

	/**
	 * Sets summa of payment <br>
	 * @param p_summa - {@link Double};
	 */
	public void setSumma(Double p_summa) {
		summa = p_summa;
	}
	
	
}
